#include "Producer.h"
#include "TaskQueue.h"
#include <stdlib.h>
#include <time.h>
#include <iostream>
#include <thread>

using namespace std;

void Producer::produce(TaskQueue & taskQue){
    srand(clock());
    int cnt = 20;
    while(cnt --){
        int num = rand() % 100;
        taskQue.push(num);
        cout << "Produce num : " << num << endl;
        this_thread::sleep_for(chrono::seconds(1));
    }
}

